how to write functions in c